<?php
	$password=$_REQUEST['password'];
	 $tel=$_REQUEST['tel'];
	$con=mysqli_connect('localhost', 'root', '', 'friday');
	
	if($con){
		mysqli_set_charset($con,'utf8');
	$sql="update accountstate set password='{$password}' where telphone='{$tel}' limit 1";
	$result=mysqli_query($con, $sql);
	$sql2="select password from accountstate  where telphone='{$tel}' limit 1";
		$result2=mysqli_query($con,$sql2);
		$arr=mysqli_fetch_all($result2,MYSQLI_ASSOC);
		$str=json_encode($arr);
		echo $str;	
	}else {
		echo "链接未遂".mysqli_connect_error();
	}
	
	
	mysqli_close($con);
	
	
	?>